Optimal. Leaf size=213 \[ \frac {2 \sqrt {c+d} \cot (e+f x) F\left (\text {ArcSin}\left (\frac {\sqrt {c+d \sec (e+f x)}}{\sqrt {c+d}}\right )|\frac {c+d}{c-d}\right ) \sqrt {\frac {d (1-\sec (e+f x))}{c+d}} \sqrt {-\frac {d (1+\sec (e+f x))}{c-d}}}{a f}+\frac {2 (a c-b d) \Pi \left (\frac {2 a}{a+b};\text {ArcSin}\left (\frac {\sqrt {1-\sec (e+f x)}}{\sqrt {2}}\right )|\frac {2 d}{c+d}\right ) \sqrt {\frac {c+d \sec (e+f x)}{c+d}} \tan (e+f x)}{a (a+b) f \sqrt {c+d \sec (e+f x)} \sqrt {-\tan ^2(e+f x)}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.25, antiderivative size = 213, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {2908, 4054,
3917, 4058} \begin {gather*} \frac {2 (a c-b d) \tan (e+f x) \sqrt {\frac {c+d \sec (e+f x)}{c+d}} \Pi \left (\frac {2 a}{a+b};\text {ArcSin}\left (\frac {\sqrt {1-\sec (e+f x)}}{\sqrt {2}}\right )|\frac {2 d}{c+d}\right )}{a f (a+b) \sqrt {-\tan ^2(e+f x)} \sqrt {c+d \sec (e+f x)}}+\frac {2 \sqrt {c+d} \cot (e+f x) \sqrt {\frac {d (1-\sec (e+f x))}{c+d}} \sqrt {-\frac {d (\sec (e+f x)+1)}{c-d}} F\left (\text {ArcSin}\left (\frac {\sqrt {c+d \sec (e+f x)}}{\sqrt {c+d}}\right )|\frac {c+d}{c-d}\right )}{a f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2908
Rule 3917
Rule 4054
Rule 4058
Rubi steps
\begin {align*} \int \frac {\sqrt {c+d \sec (e+f x)}}{a+b \cos (e+f x)} \, dx &=\int \frac {\sec (e+f x) \sqrt {c+d \sec (e+f x)}}{b+a \sec (e+f x)} \, dx\\ &=\frac {d \int \frac {\sec (e+f x)}{\sqrt {c+d \sec (e+f x)}} \, dx}{a}-\frac {(-a c+b d) \int \frac {\sec (e+f x)}{(b+a \sec (e+f x)) \sqrt {c+d \sec (e+f x)}} \, dx}{a}\\ &=\frac {2 \sqrt {c+d} \cot (e+f x) F\left (\sin ^{-1}\left (\frac {\sqrt {c+d \sec (e+f x)}}{\sqrt {c+d}}\right )|\frac {c+d}{c-d}\right ) \sqrt {\frac {d (1-\sec (e+f x))}{c+d}} \sqrt {-\frac {d (1+\sec (e+f x))}{c-d}}}{a f}+\frac {2 (a c-b d) \Pi \left (\frac {2 a}{a+b};\sin ^{-1}\left (\frac {\sqrt {1-\sec (e+f x)}}{\sqrt {2}}\right )|\frac {2 d}{c+d}\right ) \sqrt {\frac {c+d \sec (e+f x)}{c+d}} \tan (e+f x)}{a (a+b) f \sqrt {c+d \sec (e+f x)} \sqrt {-\tan ^2(e+f x)}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 6.90, size = 184, normalized size = 0.86 \begin {gather*} \frac {4 \cos ^2\left (\frac {1}{2} (e+f x)\right ) \sqrt {\frac {\cos (e+f x)}{1+\cos (e+f x)}} \sqrt {\frac {d+c \cos (e+f x)}{(c+d) (1+\cos (e+f x))}} \left (-\left ((a+b) (c-d) F\left (\text {ArcSin}\left (\tan \left (\frac {1}{2} (e+f x)\right )\right )|\frac {c-d}{c+d}\right )\right )+2 (a c-b d) \Pi \left (\frac {-a+b}{a+b};\text {ArcSin}\left (\tan \left (\frac {1}{2} (e+f x)\right )\right )|\frac {c-d}{c+d}\right )\right ) \sqrt {c+d \sec (e+f x)}}{(a-b) (a+b) f (d+c \cos (e+f x))} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 3.73, size = 357, normalized size = 1.68
method | result | size |
default | \(-\frac {2 \sqrt {\frac {d +c \cos \left (f x +e \right )}{\cos \left (f x +e \right )}}\, \sqrt {\frac {\cos \left (f x +e \right )}{\cos \left (f x +e \right )+1}}\, \sqrt {\frac {d +c \cos \left (f x +e \right )}{\left (\cos \left (f x +e \right )+1\right ) \left (c +d \right )}}\, \left (\cos \left (f x +e \right )+1\right )^{2} \left (\EllipticF \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, \sqrt {\frac {c -d}{c +d}}\right ) a c -\EllipticF \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, \sqrt {\frac {c -d}{c +d}}\right ) a d +\EllipticF \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, \sqrt {\frac {c -d}{c +d}}\right ) b c -\EllipticF \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, \sqrt {\frac {c -d}{c +d}}\right ) b d -2 \EllipticPi \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, -\frac {a -b}{a +b}, \sqrt {\frac {c -d}{c +d}}\right ) a c +2 \EllipticPi \left (\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}, -\frac {a -b}{a +b}, \sqrt {\frac {c -d}{c +d}}\right ) b d \right ) \left (\cos \left (f x +e \right )-1\right )}{f \left (d +c \cos \left (f x +e \right )\right ) \sin \left (f x +e \right )^{2} \left (a -b \right ) \left (a +b \right )}\) | \(357\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\sqrt {c + d \sec {\left (e + f x \right )}}}{a + b \cos {\left (e + f x \right )}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {\sqrt {c+\frac {d}{\cos \left (e+f\,x\right )}}}{a+b\,\cos \left (e+f\,x\right )} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________